new Vue({
	el:'#app',
	data:{
        Case_audit:{
            caseid:{
                caseId:''
            },
            auditid:{
                typeid:{
                    typeid:''
                },
                submitid:{
                    userId:''
                }
            }
        },
        tableData: []
	},
    created(){ //初始化查询待办任务
	    this.init();
    },
	methods:{
        init() {
            var userid = $.cookie("redisId");
            this.$http.post("http://localhost:8080/audit/findTaskByUserName",
                {"userid":userid},{emulateJSON:true}).then(result=>{
                var msg = eval("("+result.body+")");
                this.tableData = msg.data;
            });
        },
		handleClick(obj){  //进入流程显示页面
            console.log(obj.auditid.typeid.typeName)
            if(obj.auditid.typeid.typeName === '费用减免'){
                window.location.href="remission_money.html?processid="+obj.auditid.auditid;
            }
            if(obj.auditid.typeid.typeName === '案件审核'){
                window.location.href="case_process.html?processid="+obj.auditid.auditid;
            }
            if(obj.auditid.typeid.typeName === '用印申请'){
                window.location.href="case_seal.html?processid="+obj.auditid.auditid;
            }
            if(obj.auditid.typeid.typeName === '结案申请'){
                window.location.href="case_closelaw.html?processid="+obj.auditid.auditid;
            }
		}
	}
});